<ion-header>
    <ion-navbar color="orange">
        <ion-title>
            人才库
        </ion-title>
    </ion-navbar>
</ion-header>

<ion-content>
    <div class="flex flex-line-between ht-text-center ht-border-bottom ht-relative" style="z-index: 2;">
        
        <div class="ht-25 ht-padding-tb" (click)="isShow=1" [ngClass]="{'ht-font-f29603':isShow==1}">工种
            <span class="ht-font-14" style="vertical-align:middle">
                <ion-icon name="ios-arrow-down"></ion-icon>
            </span>
            <div class="ht-absolute option-item bg-white ht-shadow margin-top-5" style="margin-left:0"  *ngIf="isShow==1">
                    <ul class="flex flex-wrap options">
                            <li *ngFor="let work of options['target_work']" [ngClass]="{'active':util.inArray(condition['target_work'], work) > -1}" (click)="select('target_work',work)">
                                {{work}}
                            </li>
                    </ul>
                    <div padding-top>
                            <div class="ht-50 ht-float-left ht-line-50 ht-text-center ht-fff ht-666 ht-border" (click)="reset(1)">重置</div>
                            <div class="ht-50 ht-float-left ht-line-50 ht-text-center ht-fff ht-f29603" (click)="alert($event)" (click)="submit()">确定</div>
                    </div>
            </div>
            
        </div>
        <div class="ht-25 ht-padding-tb"  (click)="isShow=2" [ngClass]="{'ht-font-f29603':isShow==2}">菜系
                <span class=" ht-font-14" style="vertical-align: middle">
                        <ion-icon name="ios-arrow-down"></ion-icon>
                </span>
                <div class="ht-absolute option-item bg-white ht-shadow margin-top-5" style="margin-left:-25%"  *ngIf="isShow==2">
                        <ul class="flex flex-wrap options">
                                <li *ngFor="let cuisine of options['cuisine']" [ngClass]="{'active': util.inArray(condition['cuisine'],cuisine) > -1}" (click)="select('cuisine',cuisine)">
                                    {{cuisine}}
                                </li>
                        </ul>
                        <div padding-top>
                                <div class="ht-50 ht-float-left ht-line-50 ht-text-center ht-fff ht-666 ht-border" (click)="reset(2)">重置</div>
                                <div class="ht-50 ht-float-left ht-line-50 ht-text-center ht-fff ht-f29603" (click)="alert($event)" (click)="submit()">确定</div>
                        </div>
                </div>
                
        </div>
        <div class="ht-25 ht-padding-tb" (click)="isShow=3" [ngClass]="{'ht-font-f29603':isShow==3}">薪资
                <span class="ht-font-14" style="vertical-align: middle">
                        <ion-icon name="ios-arrow-down"></ion-icon>
                </span>
                <div class="ht-absolute option-item bg-white ht-shadow margin-top-5" style="margin-left:-50%"  *ngIf="isShow==3">
                        <ul class="flex flex-wrap options">                                
                                    <li [ngClass]="{'active': condition['money'] == 1}">
                                        <label>
                                            <input type="radio" [value]="1" name="money" [(ngModel)]="condition['money']" hidden>2000-4000
                                        </label>
                                    </li>
                                    <li [ngClass]="{'active': condition['money'] == 2}">
                                        <label>
                                            <input type="radio" [value]="2" name="money" [(ngModel)]="condition['money']" hidden>4000-6000
                                        </label>
                                    </li>
                                    <li [ngClass]="{'active': condition['money'] == 3}">
                                        <label>
                                            <input type="radio" [value]="3" name="money" [(ngModel)]="condition['money']" hidden>6000-8000
                                        </label>
                                    </li>
                                    <li [ngClass]="{'active': condition['money'] == 4}">
                                        <label>
                                            <input type="radio" [value]="4" name="money" [(ngModel)]="condition['money']" hidden>10000以上
                                        </label>
                                    </li>
                        </ul>
                        <div padding-top>
                                <div class="ht-50 ht-float-left ht-line-50 ht-text-center ht-fff ht-666 ht-border" (click)="reset(3)">重置</div>
                                <div class="ht-50 ht-float-left ht-line-50 ht-text-center ht-fff ht-f29603" (click)="alert($event)" (click)="submit()">确定</div>
                        </div>
                </div>
        </div>
        <div class="ht-25 ht-padding-tb" (click)="isShow=4" [ngClass]="{'ht-font-f29603':isShow==4}">要求
                <span class="ht-font-14" style="vertical-align: middle">
                        <ion-icon name="ios-arrow-down"></ion-icon>
                </span>
                <div class="ht-absolute option-item bg-white ht-shadow margin-top-5" style="margin-left:-75%;width: 100%" *ngIf="isShow==4">
                    <div class="title ht-text-left" padding-left>性别</div>
                    <ul class="flex flex-wrap options">
                            <li [ngClass]="{'active': condition['sex'] == 1}">
                                    <label>
                                        <input type="radio" [value]="1" name="sex" [(ngModel)]="condition['sex']" hidden>男
                                    </label>
                            </li>
                            <li [ngClass]="{'active': condition['sex'] == 2}">
                                    <label>
                                        <input type="radio" [value]="2" name="sex" [(ngModel)]="condition['sex']" hidden>女
                                    </label>
                            </li>
                    </ul>
                    <div class="title ht-text-left" padding-left>年龄</div>
                    <ul class="flex flex-wrap options">
                            <li [ngClass]="{'active': condition['age'] == 1}">
                                    <label>
                                        <input type="radio" [value]="1" name="age" [(ngModel)]="condition['age']" hidden>20岁以下
                                    </label>
                            </li>
                            <li [ngClass]="{'active': condition['age'] == 2}">
                                    <label>
                                        <input type="radio" [value]="2" name="age" [(ngModel)]="condition['age']" hidden>20-30岁
                                    </label>
                            </li>
                            <li [ngClass]="{'active': condition['age'] == 3}">
                                    <label>
                                        <input type="radio" [value]="3" name="age" [(ngModel)]="condition['age']" hidden>30-40岁
                                    </label>
                            </li>
                            <li [ngClass]="{'active': condition['age'] == 4}">
                                    <label>
                                        <input type="radio" [value]="4" name="age" [(ngModel)]="condition['age']" hidden>40-50岁
                                    </label>
                            </li>
                            <li [ngClass]="{'active': condition['age'] == 5}">
                                    <label>
                                        <input type="radio" [value]="5" name="age" [(ngModel)]="condition['age']" hidden>50岁以上
                                    </label>
                            </li>
                    </ul>
                    <div class="title ht-text-left" padding-left>厨龄</div>
                    <ul class="flex flex-wrap options">
                            <li *ngFor="let age of options['working_age']" [ngClass]="{'active':condition['working_age'] == age}">
                        <label>
                            <input type="radio" [value]="age" name="working_age" [(ngModel)]="condition['working_age']" hidden>{{age}}
                        </label>
                    </li>
                    </ul>
                    <div padding-top>
                        <div class="ht-50 ht-float-left ht-line-50 ht-text-center ht-fff ht-666 ht-border" (click)="reset(4)">重置</div>
                        <div class="ht-50 ht-float-left ht-line-50 ht-text-center ht-fff ht-f29603" (click)="alert($event)" (click)="submit()">确定</div>
                    </div>
                    
                </div>
        </div>        
    </div>
    <div class="ht-f1f1f1 ht-relative ht-overflow">
        <div style="position: absolute; top: 0;left: 0; z-index: 1;height: 100%;width: 100%; background: rgba(0, 0, 0, 0.5)" *ngIf="isShow==4||isShow==3||isShow==2||isShow==1"></div>
        <div class="bg-white margin-top-5 ht-shadow" [ngClass] = "{'resume-list-pay':resume.has_pay}"  padding *ngFor="let resume of resumeList" (click)="resumeDetail(resume['resume_id'])">                
                <div class="flex flex-line-between ht-line-20" >
                        <div class="ht-font-16 ht-bold ht-333">
                            {{resume.target_work}}
                        </div>
                        <div class="ht-font-f29603">
                            {{resume.remuneration}}
                        </div>
                </div>
                <div class="flex flex-align-center ht-font-12">
                        <span class="labelList">{{resume.sex}}</span>
                        <span class="labelList">{{resume.age}}岁</span>
                        <span class="labelList">{{resume.edu}}</span>
                        <span class="labelList">厨龄{{resume.working_age}}</span>                        
                        <span class="labelList">{{job_status == 1 ? '在职' : '离职'}}</span>
                </div>
                <div class="flex flex-align-start ht-line-30">
                        <div class="headImgBox">
                            <img src="{{resume.photo}}" alt="">
                        </div>
                        <div class="margin-left-5">
                            {{resume.nickname}}
                        </div>
                </div>
        </div>            
    </div>
    <ion-infinite-scroll (ionInfinite)="doInfinite($event)">
            <ion-infinite-scroll-content></ion-infinite-scroll-content>
    </ion-infinite-scroll>
</ion-content>